
package SBLib;

import java.io.BufferedWriter;
import java.io.FileWriter;
import java.io.IOException;
import java.util.logging.Level;
import java.util.logging.Logger;
import server.FileIO;

/**
 * User object is a User that has registered with the system. 
 * 
 * - This class doesn't really have anything yet besides getters and setters.
 * @author BrandonNeal
 */
public class User {
    private String userName;
    private String password;
    private String IPaddress;

  
    
    public User()
    {
        
    }
    public User(String userName, String password)
    {
        this.userName = userName;
        this.password = password;
    }
    public void SaveUser()
    {
       FileIO.SaveFile(FileIO.USER_DIR+this.userName, this.password);
    }
    /**
     * @return the userName
     */
    public String getUserName() {
        return userName;
    }

    /**
     * @param userName the userName to set
     */
    public void setUserName(String userName) {
        this.userName = userName;
    }

    /**
     * @return the password
     */
    public String getPassword() {
        return password;
    }

    /**
     * @param password the password to set
     */
    public void setPassword(String password) {
        this.password = password;
    }
    
    public void setIP(String IPaddy)
    {
        this.IPaddress=IPaddy;
    }
    public String getIP()
    {
        return this.IPaddress;
    }
}
